<?php
/**
 * Created by PhpStorm.
 * User: mww
 * Date: 2018/12/17
 * Time: 16:08
 */
namespace app\index\controller;
use think\Db;
class Seelist extends Base
{
    /**
     * 购物车首页
     */
    public function index()
    {
        extract(input());
        $data = [];
        if(isset($keyword) && $keyword){
            $where = [
                's_verify' => 2,
                's_name|s_com_name|s_area_str|s_address|s_phone|s_phone1|s_phone2' => ['like','%'.$keyword.'%'],
            ];
            $data = Db::table('up_shop')
                ->where($where)
                ->field('s_id,s_com_name,s_u_name,s_inside_name,s_status')
                ->select();
        }else{
            $keyword = '';
        }
        $this->assign('keyword',$keyword);
        $this->assign('data',$data);
        return $this->fetch();
    }
}